package com.wudl.realtime.config;




import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.io.InputStream;
import java.util.Map;
import java.util.Properties;
/**
 * @author ：wudl
 * @date ：Created in 2021-12-23 23:43
 * @description：
 * @modified By：
 * @version: 1.0
 */

public class QuotConfig {
    private static final Logger log =  LoggerFactory.getLogger(QuotConfig.class);
    public final static Properties config = new Properties();

    static {
        InputStream profile = QuotConfig.class.getClassLoader().getResourceAsStream("config.properties");
        try {
            config.load(profile);
        } catch (Exception e) {
            log.debug("load profile error!");
        }
        for(Map.Entry<Object,Object> kv:config.entrySet()){
            log.debug(kv.getKey()+"="+kv.getValue());
        }
    }

    public static void main(String[] args) {
        String property = config.getProperty("bootstrap.servers");
        System.out.println(property);
    }
}
